Log In  
BBS > Lexaloffle Community Superblog
This is a combined feed of all Lexaloffle user blogs. For Lexaloffle-related news, see @zep's blog.

All | Following | PICO-8 | Voxatron | General | Off-site
[ :: Read More :: ]

Cart #picoctober_2019_04-0 | 2019-10-05 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Day 4 of PicOctober! Started a empty cart in order to take part in the Ludum Dare 45 compo! The theme is start with nothing, and the rules require me to do just that! Wrote a co-routine to display centered text.

P#68497 2019-10-05 03:16
[ :: Read More :: ]

Cart #razejejose-0 | 2019-10-05 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1

P#68490 2019-10-05 01:22 ( Edited 2019-11-16 17:55)
[ :: Read More :: ]

Cart #ld45warmup-0 | 2019-10-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

I made a quick warm-up game in 2-3 hours!

P#68481 2019-10-04 21:58
[ :: Read More :: ]

Before I set out on a long journey of code, I wanted to know if Pico-8 had the ability to do something like this:

a=sum("(3+4)*2")
print(a)

Where the answer would come back 12. And yes, the statement needs to be in a string and be able to handle one or more parentheses math.

The TRS-80 could do this:

INPUT A$
PRINT A$

And B4GL could as well.

INPUT A$
CODE("PRINT "+A$)
P#68477 2019-10-04 20:45 ( Edited 2019-10-04 21:15)
[ :: Read More :: ]

I've noticed some games (such as https://krajzeg.itch.io/dank-tomb... and my current game I'm working on) perform very poorly in Firefox on Mac - low and uneven frame rates. The same games run fine on Firefox/Linux and Chrome or Safari on Mac.

Is this a known issue for Pico8, or is there anyway I can troubleshoot this?

In the browser's dev console it starts with >codo_init, platform: Emscripten

So perhaps it's an Emscripten issue and I'll have a look over there.

Thanks!

P#68475 2019-10-04 20:42 ( Edited 2019-10-05 17:55)
[ :: Read More :: ]

Cart #brickdemo-0 | 2019-10-04 | Code ▽ | Embed ▽ | No License

This is a work in progress made for my video game development class. More to come!

P#68469 2019-10-04 19:48
[ :: Read More :: ]

Cart #picoparty0-0 | 2019-10-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1

just a lil town thing

[0x0]

P#68462 2019-10-04 19:08 ( Edited 2019-10-04 19:26)
[ :: Read More :: ]

Was curious to know if this was a problem ?

And possibly for others who need exact math in their calculations.

P#68461 2019-10-04 18:18 ( Edited 2022-03-20 19:09)
[ :: Read More :: ]

This may be old hat to you veterans, but is there an easier way to look for a non-value than this ?

function sum(a,b)
  if a==nil or a=="" or b==nil or b=="" then
    return
  end
((rest of function)
end
P#68453 2019-10-04 16:19 ( Edited 2019-10-04 18:14)
[ :: Read More :: ]

Cart #altenhofen_showandtell-0 | 2019-10-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

P#68449 2019-10-04 14:19
[ :: Read More :: ]

PICO-8 iPhone Shell

This is a work-in-progress iPhone Shell for PICO-8 featuring

  • sound
  • real gamepad controls (digital and analog)
  • pixel-perfect scaling
  • low latency (run loop reading input runs 60 times a second)

Note: I am abandoning this project because I now use the ClockworkPi Gameshell.

It uses the Gamepad API that was introduced with iOS 11 and was tested with the following MiFI-Controllers:

Controller Working
Kanex GoPlay Sidekick Yes
SteelSeries Stratus Yes after Firmware Update
Logitech PowerShell Controller No

No more touch support at the moment.

On the iPhone SE you have pixel-perfect scaling. Since the iPhone SE's display is 640 pixels wide you can do a 5x integer scale for razor sharp pixels. For a more full-screen experience turn the phone sideways.

Click to start the game (necessary to enable audio).

You can test it out on your phone:

https://pixelpunker.github.io/pico8-iphone/iphone.html

To Change the Game

Load your PICO-8 cart and export it as html with this command

export mygame.html

Keep the mygame.js file and throw away the other files. Change line 66 in iPhone.html to reference your exported cart.

Todo:

  • Use new fullscreen API in iOS 12/13
  • Test other bluetooth controllers in iOS 13
  • Does saving to home screen work now? (Pinning the website to the homescreen used to disable Gamepad functionality)
P#68447 2019-10-04 12:52 ( Edited 2019-10-06 13:46)
[ :: Read More :: ]

Cart #earthdefence-0 | 2019-10-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA


[#earth defence-0#]
Here's Earth Defence by Indy, aged 7!

You are the buggy with the intergalactic catcher on top.Catch the meteors and asteroids before they hit the earth!

this is the working version - more bits and pieces may be added later!

P#68444 2019-10-04 10:40 ( Edited 2019-10-04 10:42)
[ :: Read More :: ]

Cart #bjk_batty-5 | 2019-10-11 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
4

Made for Spooky September 4 Color Jam.

You're a bat. Flap your wings with Z. Boost for 100 coins with X. Fly as far as you can, and collect coins as you go.

Changes
revision 2: Fixed but where you could go forever if you dropped off the screen
revision 3: Add boost. Add effects. Add (temporary) sounds.
revision 4: Final version for the jam! (-ish)

P#68443 2019-10-04 10:01 ( Edited 2019-10-11 09:44)
[ :: Read More :: ]

Cart #wepubosaya-0 | 2019-10-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA


A timestables studying game for Scarlett!

P#68439 2019-10-04 06:11 ( Edited 2019-10-04 06:12)
[ :: Read More :: ]

Cart #picoctober_2019_03-0 | 2019-10-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
2

Day 3 of PicOctober. Added some vines, took a suggestion to use the sprite-sheet for characters instead of strings from @dw817. Added some bound tests on the pumpkin.

P#68433 2019-10-04 04:04 ( Edited 2019-10-04 04:05)
[ :: Read More :: ]

Cart #huzodebeta-0 | 2019-10-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

P#68431 2019-10-04 01:04
[ :: Read More :: ]

cds
by dw817
Cart #cds-1 | 2019-10-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
3

Hmm ... You press ENTER in the BBS and it pauses, okay, run it local or use the spacebar instead.

Also, use the "=" as the backspace key and the "[" key for letter P.

As you know or should by watching how to write game in Pico-8 or doing so yourself, there is a nifty function called FGET() which will let you retrieve whether or not up to 8-flags are being set for a sprite of your choosing.

You can see pointing right at them HERE.

So how do they work ? Very simply. You click on them, up to 8 and using the command FGET followed by the sprite # you get the value of TRUE or FALSE whether or not that particular flag # (0-7) is set.

Not bad, but it could be better. That's where I come in with my new code. :)

So what does it do ?

Well for one thing is it lets you add a lot more definition and ease of retrieval for your sprites.

For instance, here is the string generated by the builder. You don't need to modify the string manually as I've created a program to edit each individual sprite, but it's still important to see what it looks like:

0[blank[[1[player[[2[floor[[3[wall[w[4[switch[[5[up[w[6[down[[7[treasure[w[8[empty[w[9[note[w[10[frenzy[[11[home[[12[zap[[17[blu[[18[bld[[19[bll[[20[blr[[63[marker[[

The data is separated into 3-parts. The first is the sprite # to contain this special data. The next is the name of the sprite, up to 8-chars you remember. The next is any sprite flags that exist for that sprite, and there can be up to 52 in any order for each sprite. You will see some of them have "W" set meaning Wall. So while you can name the sprites anything you want, you can also individually switch on and off the 52-flags available for them.

So what are the 52-flags ? That would be these:

.!?,;:#$%&-+*/=()<>{}|~^_@abcdefghijklmnopqrstuvwxyz

Assume in Pico-8 that these are uppercase. Why no digits ? Because if you call FFGET() with digits it assumes that you are requesting either the text name or status of the flags based on your numeric entry. Let's continue.

Now run the program above and select a sprite with the arrow keys, press ENTER and you can enter an up to 8-character name for it.

Press ENTER again and you can hit any of those characters you see below and that becomes a flag. This would be real nightmare to do with numbers and a modified FGET() though, right ?

Not to worry.

You see, the way I set it, you can retrieve all the following:

PRINT FFGET(number)
ANSWER: text name of that sprite.
PRINT FFGET(name)
ANSWER: number of that sprite on the sheet, zero being the first.
PRINT FFGET(1st character of name)
ANSWER: also the same number

Let's pause for a second. That last one is a little tricky. If you have more than one sprite that you have named with the same beginning character, it will only choose the last one calculated. It's not a reliable method if you have more than 26-sprites and you should choose the full-name or number each time in your code if you have dozens of sprites with definitions. Okay, let's continue. How are the flags handled ? Quite simply.

PRINT FFGET(number),(number)
ANSWER: the condition of whether that sprite #'s flag # is TRUE or FALSE
PRINT FFGET(name),(number)
ANSWER: same as above
PRINT FFGET(number),(single string character of flag)
ANSWER: same as above
PRINT FFGET(name),(string character of flag)
ANSWER: same as above

Let's see this in action with the sprite, WALL.

Quite a bit is happening, first off the total number of sprites (range) is 63 by printing SPR_TOTAL.

Then we are printing SPR_FLAGCHARS which are the 52-choices available to set flags for that individual sprite, ON or OFF, TRUE or FALSE.

Next is SPR_FLAGS which as described above is the string you need to copy to your code to have these flags set for your sprites.

Now we're using FFGET(). The wall is sprite #3. 48 is the letter "W" from the table. And you can see how it's possible to mix and match them quite thoroughly and still get the results you want.

If you only have one argument for FFGET() though, if it's a number it will retrieve the name of the sprite. If it's the name it will reverse and give you the number.

Example, to plot the player:

spr(ffget("player"),x,y)
or
spr(ffget("p"),x,y)
provided you only have one sprite name that begins with "p"

And that's it !

For your use, IMPORT your own sprite table. Run the program. Set your flags. Press "\" to save to clipboard. In a separate PICO-8 task (you should have 2 running). PASTE that string at the top of your _INIT() code. Then copy that one line in the first cart, the one called SPR_INIT(). Call that from your _INIT() code.

And you're done !

This is a considerably more robust flag system than PICO-8 came with. This demo also uses 1% of your onboard memory so it should work fine for you. I hope you use it and if you do, please let me know. Would love to see how you are getting on it.

And yes, those sprites included - I plan to make a game sometime later demonstrating the use of this new sprite library so no borrowing them for your projects just yet. :)

If you have any questions, and you might as this is a pretty busy upgrade going on here, feel free to let me know.

P#68427 2019-10-04 00:21 ( Edited 2019-10-04 03:45)
[ :: Read More :: ]

Cart #sazumozhu-0 | 2019-10-04 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA
1


Created for a class for Intro to Game Development. Work in progress!

P#68428 2019-10-04 00:09
[ :: Read More :: ]

Alright so you've been using PICO for a-while now and have gotten used to the limitations on the sound. But then occasionally you come across a snazzy cart that has sound you are CERTAIN is just not possible with the limitations of Pico-8, or so you think.

So what gives ?

Well let's see if we can discover what's going on. First off save off the work on your current cart and REBOOT.

Let's start with a clean slate. Press the ESC key and ALT-RIGHT arrow key three times and TAB until you are at the sound editor.

Let's start with something basic. The rain sound. To make this, type out the following. You can create that "C" with letter Z.

Then click on the right-most number of LOOP to 1 so it shows LOOP 00 01 and press SPACEBAR to hear it.

Familiar. But is that as low pitch as the sound can go ? Well, yes and no.

Let's now discover something new. Hit SPACEBAR again to stop playing. Now, do you see that tiny little button just below the 2nd number for LOOP. Well, click on it.

Now this is different ! Your waveforms have been replaced with digits now 0-7 and you can see the button is active as it is GREEN.

Hit = and TAB to go to the next sound. From here, type out:

NOTICE the center number is no longer PINK but GREEN. This is a special case.

Set the loop here to 00 and 01 like the first sound and press SPACEBAR.

Well there's a sound you haven't heard in PICO before. So what's going on here.

When you use GREEN for your note instead of PINK you will be using THAT sound # as the instrument itself. In this case, you can see the zero is green so it means we are using the 1st sound as OUR instrument and are telling it to play it at an even lower pitch.

For low sounds you likely won't get much improvement as the audio is pretty raspy to begin with. But for high-pitch ? Well, let's try an experiment, shall we ?

Hit = and TAB again to go to the 3rd page for sounds. This time we're going to leave the LOOP at 00 and 00, but we ARE going to do something tricky.

Try this. First off hold down the "." key until your SPD is 255. We want it to play a good long time. Now type out the following:

Let's take a look at it letter per number.

It has a C so that's just the note. The next is is pitch, high as it will get. The GREEN number says to use - well - to use THIS sound as its instrument. This oughta be interesting. The next is 7, loud, and the last, the warble effect.

Get ready to hear a sound you've never heard in PICO before ! Press SPACEBAR to hear it.

Hope that didn't scare the cat ! :D

What's going on here ? Well, you're doing a feedback essentially. Like when a microphone gets too close to the speaker. You get this interesting warbling feedback effect. You could also get this trying to tune an AM radio.

So let's recap. The green number then means to use the SOUND # (0-7), sorry there are no more, to use as an instrument. So ... How could we use this to our advantage ? We've still got a bit of space. Let's do something fancy indeed.

If you have trouble typing this in, there's a copy of this cart at the end of the document.

Now on the next page have the following:

Notice that we have speed here set to 255 as well. So what do you think will happen ? Press SPACEBAR to play and find out.

Ah ! So it is indeed possible to play a sound that has tones as a single instrument itself and most importantly CHANGE THE KEY it is playing in.

And of course you can play something really high pitched as the instrument and then use a 2nd sound to play it even higher pitch getting some interesting sound effects not possible before this.

What amazing sounds will you discover ? Feel free to share.

Here is the sound set I put together.

Cart #jumugujido-0 | 2019-10-03 | Code ▽ | Embed ▽ | No License
1

HOPE THIS HELPS !

P#68406 2019-10-03 17:14 ( Edited 2019-10-03 19:34)
[ :: Read More :: ]

Cart #binabiteki-5 | 2019-10-12 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Cart #binabiteki-4 | 2019-10-08 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Cart #binabiteki-3 | 2019-10-07 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Cart #binabiteki-2 | 2019-10-06 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Cart #binabiteki-0 | 2019-10-03 | Code ▽ | Embed ▽ | License: CC4-BY-NC-SA

Hello,

This is my first game with pico 8.

It's about fishing, inspirate by the new zelda game reboot. It's not finished but one day it will be ! :)

-In the future i will be able to fear or baith the fish
-Adding random direction for the fish
-Good music and sound :)

0.3
-added animation

0.5
-added power jauge
-added launch distance

0.6
-new menu

P#68411 2019-10-03 16:52 ( Edited 2019-10-12 18:34)
View Older Posts